﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.ComponentModel;
using System.Collections.ObjectModel;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;

namespace IndexMarkSilverlightClient.IndexMarkServiceReference
{
    public partial class Section
    {
        [DataMember]
        public override bool IsResponsible
        {
            get
            {
                foreach (DTOBase DTO in Childs)
                {
                    if ((DTO as IndexMarkItem).IsResponsible)
                    {
                        return true;
                    }
                }
                return false;
            }
        }

        public override string ToString()
        {
            return "P" + this.Order + " - "  + this.Name;
        }


        public bool Check { get; set; }
    }
}
